home *** CD-ROM | disk | FTP | other *** search
/ Galleria D'arte: Manet / Manet.iso / Dati / Mappa.dxr / Internal_16_evidenzia stato-collezioni.ls < prev    next >
Encoding:
Text File  |  2000-12-21  |  2.2 KB  |  76 lines

  1. global oldlinea, gLineaSel, gNomeFileSel, gIDSel, gLinea, gNomeFile
  2.  
  3. on mouseEnter me
  4.   oldlinea = 0
  5. end
  6.  
  7. on mouseWithin me
  8.   newlinea = the mouseLine
  9.   tmp = the member of sprite the currentSpriteNum
  10.   nome = member(tmp).name
  11.   cursor(280)
  12.   if newlinea <> oldlinea then
  13.     if (oldlinea <> gLineaSel) and (oldlinea <> 0) then
  14.       set the foreColor of line oldlinea of field tmp to 255
  15.     end if
  16.     if nome = "collezioniTXT" then
  17.       the itemDelimiter = "#"
  18.       titolo = line newlinea of field "collezioniTXT"
  19.       repeat with i = 1 to the number of lines in field "titolo#nomefile"
  20.         linea2 = line i of field "titolo#nomefile"
  21.         gNomeFileSel = item 1 of linea2
  22.         if gNomeFileSel = titolo then
  23.           gNomeFileSel = item 2 of linea2
  24.           gIDSel = item 3 of linea2
  25.           gIDSel = integer(gIDSel)
  26.           set the member of sprite 18 to member(gNomeFileSel)
  27.           updateStage()
  28.           exit repeat
  29.         end if
  30.       end repeat
  31.     end if
  32.     if the foreColor of line newlinea of field tmp <> 6 then
  33.       set the foreColor of line newlinea of field tmp to 3
  34.     end if
  35.     oldlinea = newlinea
  36.   end if
  37. end
  38.  
  39. on mouseLeave me
  40.   oldlinea = 0
  41.   set the member of sprite 18 to member("dummyquadro")
  42.   cursor(-1)
  43.   newlinea = the mouseLine
  44.   tmp = the member of sprite the currentSpriteNum
  45.   nome = member(tmp).name
  46.   if gLineaSel > 1 then
  47.     set the foreColor of line 1 to gLineaSel - 1 of field tmp to 255
  48.     set the foreColor of line gLineaSel + 1 to the number of lines in field tmp of field tmp to 255
  49.   else
  50.     if gLineaSel = 1 then
  51.       set the foreColor of line gLineaSel + 1 to the number of lines in field tmp of field tmp to 255
  52.     else
  53.       if gLineaSel = 0 then
  54.         set the foreColor of field tmp to 255
  55.       end if
  56.     end if
  57.   end if
  58.   if nome = "collezioniTXT" then
  59.     if gLineaSel <> 0 then
  60.       gNomeFileSel = gNomeFile
  61.       set the member of sprite 18 to gNomeFileSel
  62.     end if
  63.   end if
  64. end
  65.  
  66. on mouseDown me
  67.   newlinea = the mouseLine
  68.   tmp = the member of sprite the currentSpriteNum
  69.   nome = member(tmp).name
  70.   if (gLineaSel <> 0) and (gLineaSel <> the mouseLine) then
  71.     set the foreColor of line gLineaSel of field tmp to 255
  72.   end if
  73.   gLinea = the mouseLine
  74.   set the foreColor of line gLinea of field tmp to 19
  75. end
  76.